$(function(){
	

		YuXi.InfoQuery.init({	
		url:"getAlreadyDoInfoFlow.do",
		query:{
				
				flowId:2,//修改为当前的流程ID
				currentPage:1
			},					
		success:function(data){					
				YuXi.Render.InformationSeach(data.list,4,"初审-已提交");//调用信息查询的页面渲染模块
			},
			getQueryParm:function(){
						var query={};
						query={
							flowId:2,//修改为当前的流程ID
							currentPage:1
						}
						YuXi.InfoQuery.queryData=YuXi.ALLSearch.base(query);
					},
				error:function(){},
				/* selector:{
					nextPage:$("#nextPage"),
					prevPage:$("#prevPage"),
					firstPage:$("#headPage"),
					lastPage:$("#endPage"),
					totalPage:$("#totalPage")
					此项为默认项
				}	 */
		});	
 	
  //跳转到详情界面
  $("#tablebody").parent().on("click", ".dealDetail", function() {
	  var id= $(this).attr("data-id");
		var menuId=$("#menu-container").attr("menu-id");
		window.location.href = '../information/subDetailInfo.jsp?menuId='+menuId+'&detailId=' + id;
  })
  $("#ExcelFrist").click(function(){
	  $(".export-form").attr("action","/yuxi/LoginFilter/importExcel.do").submit();
  });
	  $("#ExcelRsRj").click(function(){
			//  $(".export-form").attr("action","/yuxi/LoginFilter/exportExcelRsRj.do").submit();
			 $("#infoJudge").modal("show");
		  });
		  
		  $("#exportWord-btn-word-own").click(function(){
			  var start=$(".export-start-time").val();
			  var end=$(".export-end-time").val();
			  if(start=="请选择起始时间"||end=="请选择结束时间"){
				  myTool.alert({
					  title:"提示",
					  context:"请选择时间"
				  });
				  return false;
			  }
			  
			  $("#export-form-own").submit();
		  });
		  $("#export-form-own").submit(function(){
			  var start=$(".export-start-time").val();
			  var end=$(".export-end-time").val();
			  if(start=="请选择起始时间"||end=="请选择结束时间"){
				  myTool.alert({
					  title:"提示",
					  context:"请选择时间"
				  });
				  return false;
			  }
			 
		  });
  

  $(".export-form").submit(function(){
		var check=$("input[name='idArray']:checked");
		if(check.length<=0){
			myTool.alert({
				title:"提示",
				context:"请勾选导出信息",
				isMask:true  
			});		
			return false;
		}
		
		if(check==null){
			myTool.alert({
				title:"提示",
				context:"请勾选导出信息",
				isMask:true
			});		
			return false;
		}
		return true;
  });





})
